package cn.iocoder.yudao.module.call.dal.mysql.ivrtimbre;

import java.util.*;

import cn.iocoder.yudao.framework.common.pojo.PageResult;
import cn.iocoder.yudao.framework.mybatis.core.query.LambdaQueryWrapperX;
import cn.iocoder.yudao.framework.mybatis.core.mapper.BaseMapperX;
import cn.iocoder.yudao.module.call.dal.dataobject.ivrtimbre.IvrTimbreDO;
import org.apache.ibatis.annotations.Mapper;
import cn.iocoder.yudao.module.call.controller.admin.ivrtimbre.vo.*;

/**
 * ivr-音色 Mapper
 *
 * @author 数创万维
 */
@Mapper
public interface IvrTimbreMapper extends BaseMapperX<IvrTimbreDO> {

    default PageResult<IvrTimbreDO> selectPage(IvrTimbrePageReqVO reqVO) {
        return selectPage(reqVO, new LambdaQueryWrapperX<IvrTimbreDO>()
                .eqIfPresent(IvrTimbreDO::getTimbreId, reqVO.getTimbreId())
                .likeIfPresent(IvrTimbreDO::getTimbreName, reqVO.getTimbreName())
                .betweenIfPresent(IvrTimbreDO::getCreateTime, reqVO.getCreateTime())
                .orderByDesc(IvrTimbreDO::getId));
    }

}